<?php
declare (strict_types=1);

namespace app\admin\command;

use app\admin\model\OilOrder;
use app\admin\model\Order;
use app\admin\model\Wechat;
use GuzzleHttp\Client;
use think\console\Command;
use think\console\Input;
use think\console\Output;

class Test extends Command
{
    protected function configure()
    {
        // 指令配置
        $this->setName('test')
            ->setDescription('the test command');
    }

    protected function execute(Input $input, Output $output)
    {
        // // 66_mdEW8OX9mWsuGhDXtkPbKGbO8GwbmQNmxXY_23k-waKgXBwKAwtJjA4APnu87rEXMoQairpd2h72I6-KXdUyd80H7ALXsTWcxnYQ1bX4GUUUsn2WAUQHVi3fA68ASShAEAGYY
        // $wechat = new Wechat();
        //
        // $token = $wechat->getAccessToken();
        // var_dump($token);
        //
        // die;
        // $num = [];
        // for ($i = 0; $i < 30; $i++) {
        //     $num[] = rand(500, 800);
        // }
        // $output->writeln(json_encode($num));
        // die;
        $order = new OilOrder();
        $order->paySuccess([
            'out_trade_no' => '202303171540515923122661',
            'transaction_id' => 'test',
        ]);
    }
}
